package com.bl.pet.domain;

import java.math.BigDecimal;
import java.util.Date;
import com.bl.basic.domain.BaseDomain;
import com.bl.org.domain.Shop;
import com.bl.user.domain.User;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

/**
 * 实体类：
 */
@Data
public class Pet extends BaseDomain{

    private static final long serialVersionUID = 1L;
    /**
     *  宠物名称
     */
    private String name;
    /**
     * 销售价
     */
    private BigDecimal saleprice;
    /**
     *  成本价
     */
    private BigDecimal costprice;
    /**
     *  宠物详情图片
     */
    private String resources;
    /**
     * 状态：0下架 1上架 默認下架
     */
    private Long state = 0L;
    /**
     * 类型id
     */
    private Long typeId;
    private PetType type;
    /**
     *  下架时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd'"+"\r\n"+"'HH:mm:ss",timezone = "GMT+8")
    private Date offsaletime = new Date();
    /**
     * 上架时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd'"+"\r\n"+"'HH:mm:ss",timezone = "GMT+8")
    private Date onsaletime = new Date();
    /**
     *  创建时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd'"+"\r\n"+"'HH:mm:ss",timezone = "GMT+8")
    private Date createtime = new Date();
    /**
     * 店铺Id 如果被领养店铺id为null
     */
    private Long shopId;
    private Shop shop;
    /**
     * 如果被领养为领养用户id
     */
    private Long userId;
    private User user;
    /**
     *  寻主Id
     */
    private Long searchMasterMsgId;

    private Integer auditnum;

    private String note;

    // 添加是需要的宠物详情
    private  PetDetail petDetail;

}
